//
//  Primer_available_DemoVC.swift
//  APSwift
//
//  Created by jianbo.pei on 2022/4/10.
//

import UIKit

class Primer_available_Person {
    /*
     ⚠️：存储属性不能用`@available`
     Stored properties cannot be marked potentially unavailable with '@available'
     */
//    @available(iOS 14, *)
//    var nickName: String?
}

class Primer_available_DemoVC: UIViewController {

    override func viewDidLoad() {
        super.viewDidLoad()

        // Do any additional setup after loading the view.
        test1()
    }
    
    private func test1() {
//        let p1 = Primer_available_Person()
//        p1.nickName = "jianbo.pei"
//        print("p1 nickName is \(String(describing: p1.nickName))")
        let customV = Primer_CustomView(bgColor: .red)
        customV.frame = CGRect(x: 50, y:100, width: 200, height: 100)
        view.addSubview(customV)
    }

}
